<template>
  <el-row class="homeproduct-total">
    <!-- <div></div> -->
    <div class="homeproduct">
      <div class="homeproduct-about">
        <div class="homeproduct-about_left">
          <h2 class="homeproduct-about_red">
            产品中心
          </h2>
        </div>
      </div>
      <div class="homepage-main">
        <div class="homepage-main_shang">
          <!-- 第一张图 -->
          <!-- <router-link to="/Productcenter?id" class="link"> -->
          <div class="homepage-img_video" v-for="(item,index) in items" :key="index" @click="">
            <router-link :to="item.id">
              <div class="homepage-img_window">
                <img class="imag" :src="item.src" alt="">

                <div class="img-text">
                  <span>{{item.text}}</span>
                </div>
                <!-- <img class="imag" :src="item.src" alt="">
                <div class="img-text">
                  <a href="">{{item.text}}</a>
                </div> -->
              </div>
            </router-link>
            <!-- <div>{{item.text}}</div> -->
          </div>
          <!-- </router-link> -->
        </div>
      </div>
    </div>
  </el-row>
</template>
<script>
    export default {
        name: "Homeproduct",
        data () {
            return {
                items:[
                    {
                        id:'/Productcenter?1-1',
                        src:require('../assets/homeproduct/环形穿梭车系统.jpeg'),
                        text:'环形穿梭车系统'
                    },
                    {
                        id:'/Productcenter?1-2',
                        src:require('../assets/homeproduct/高速分拣系统.jpg'),
                        text:'高速分拣系统'
                    },
                    {
                        id:'/Productcenter?1-3',
                        src:require('../assets/homeproduct/四向车系统.jpg'),
                        text:'四向车系统'
                    },
                    {
                        id:'/Productcenter?1-4',
                        src:require('../assets/homeproduct/WarehouseSystem.jpg'),
                        text:'WMS/WCS智能仓储管理/控制系统'
                    },
                    {
                        id:'/Productcenter?2-1',
                        src:require('../assets/homeproduct/堆垛机.jpg'),
                        text:'堆垛机'
                    },
                    {
                        id:'/Productcenter?2-2',
                        src:require('../assets/homeproduct/RGV.jpg'),
                        text:'RGV'
                    },
                    {
                        id:'/Productcenter?2-3',
                        src:require('../assets/homeproduct/升降机.jpg'),
                        text:'升降机'
                    },
                    {
                        id:'/Productcenter?2-9',
                        src:require('../assets/homeproduct/AvgSystem.jpg'),
                        text:'AGV'
                    }
                ],
            }
        }
    }
</script>
<style scoped>

  .homeproduct-total{
    width: 100%;
    height: 100%;
    /* margin: 0 auto; */
    background-color: #ececec;
    margin-top: 5%;
  }
  .homeproduct{
    width: 80%;
    height: 100%;
    margin: 0 auto;
    /* background-color: #ececec; */
    margin-top: 5%;
    margin-bottom: 5%;
  }
  .homeproduct-about{
    width: 90%;
    height: 100%;
    display: flex;
    justify-content: space-between;
  }
  .homeproduct-about_left{
    width: 150px;
    height: 50px;
    justify-content: center;
    align-items: center;
    /* background-color: red; */
    /* line-height:50px; */
  }
  .homeproduct-about_red::before {
    content: '';
    /* display: inline-block; */
    width: 4px;
    height: 24px;
    background-color: rgb(64, 158, 255);
    float: left;
    /* display: flex; */
    /* margin-left: 14px; */
    margin-right: 20%;
    /* margin-right: 48px; */
    /* justify-content: center;
    align-content: center;
    text-align: center; */
    margin-top:3%;
  }
  .homeproduct-about_red > h2{
    /* margin-right: -50px; */
    /* margin-top: 10px; */
    /* display: flex; */
    float: left;
  }
  .homepage-main{
    width: 100%;
    height: 100%;
    /* border: 1px solid red; */
    margin-top:3%;
  }
  .homepage-main_shang{
    width: 100%;
    height: 100%;
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    /* align-content: ; */
  }

  .homepage-img_video{
    width: 24%;
    height:50%;
    /* border: 1px solid green; */
    padding-bottom: 2%;
  }
  .homepage-img_video:hover .imag{
    transform: scale(1.2);


  }
  .homepage-img_video:hover .img-text {
    transform: translateY(-25px);
  }
  .homepage-img_video:hover .img-text {
    color: rgb(64, 158, 255);
  }
  .homepage-img_video > div{
    text-align: center;
  }
  .homepage-img_window{
    width: 100%;
    height: 100%;
    overflow: hidden;
    background-color: #fff;
    /* border: 1px solid blueviolet; */
  }
  .imag{
    width: 100%;
    height: 90%;
    display: block;
    /*border: 1px solid yellow;*/
    transition: transform .8s;
    box-shadow: 0px -10px 10px rgb(64, 158, 255);
    aspect-ratio: 16/9;
  }
  .img-text{
    width: 100%;
    height: 68px;
    position: relative;
    top: -21px;
    background-color: #fff;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: transform .8s;
  }
  .img-text > span{
    font-weight: bolder;
  }

  @media screen and (max-width: 992px){
    .homepage-img_video{
      width: 48%;
      height: 100%;
      flex-shrink: 0;
      /* border: 1px solid red; */
      /* background-color: blue; */
    }
    .homepage-img_video > div {
      font-size: 16px;
      font-weight: bolder;
    }
    .homepage-img_video > img {
      width: 90%;
      height: 100%;
      /* margin-right: 2%; */
      margin-left: 5%;
    }
    .img-text{
      width: 100%;
      height: 40px;
      display: flex;
      justify-content: center;
      align-items: center;
    }
    /* .img-text > a{
      text-align: center;
      line-height: center;
    } */
    .homeproduct{
      margin-top: 5%;
    }
    .homeproduct-about_red::before{
      margin-right: 12px;
      font-size: 12px;
    }
    .homepage-main{
      margin-top: 5%;
    }
    .homeproduct-total{
      margin-top: 10%;
    }
  }
</style>
